﻿<%@ Page Title="" Language="C#" MasterPageFile="~/master/m.master" %>

<script runat="server"></script>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <link href="../assets/js/plugins/fancybox/jquery.fancybox.css" rel="stylesheet">
    <link href="../assets/css/shelf/base.css" rel="stylesheet">
    <link href="../assets/css/enterpriseLayout/makePlan.css" rel="stylesheet" />
    <link href="../assets/css/plugins/webuploader/webuploader.css" rel="stylesheet" />
    <style>
        .tb-head-container {
            padding: 5px 0 0 0;
        }

        #tbc .pic {
            width: 40px;
            height: 40px;
            margin: 2px auto;
        }

        #thc span,
        #tbc span {
            display: inline-block;
        }

        .condition {
            padding-top: 5px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="main" runat="Server">
    <div class="system-box">
        <div class="right-side">
            <div class="btns-container"></div>
            <div class="condition">
                <label>类别</label>
                <select class="form-control input-w160" id="serarch-type">
                    <option value="">请选择</option>
                </select>
                <label>品类</label>
                <select class="form-control input-w160" id="serarch-category">
                    <option value="">请选择</option>
                </select>
                <label>商品年份</label>
                <select class="form-control input-w160" id="serarch-year">
                    <option value="">请选择</option>
                </select>
                <label>商品季节</label>
                <select class="form-control input-w160" id="serarch-season">
                    <option value="">请选择</option>
                </select>
            </div>
            <div class="condition">
                <label>省份</label>
                <select class="form-control input-w160" id="serarch-province">
                    <option value="">请选择</option>
                </select>
                <label>城市</label>
                <select class="form-control input-w160" id="serarch-city">
                    <option value="">请选择</option>
                </select>
                <label>调拨时间</label>
                <input type="text" class="form-control layer-date" id="search-start" readonly="readonly" placeholder="调拨时间" />
                <label>查询条件</label>
                <input type="text" class="form-control input-w170" placeholder="店铺代码、名称或货号" id="search-keys" />
            </div>
            <div style="overflow: auto; background: #fff;">
                <div class="tb-head-container" id="thc">
                    <div class="ibox-content">
                        <table class="loadTable">
                            <thead>
                                <tr>
                                    <th rowspan="2" class="diy-td-w250"><span style="width: 250px;">店铺</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">项目</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">图片</span></th>
                                    <th rowspan="2" class="diy-td-w100"><span style="width: 100px;">货号</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">城市</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">近(30-60)天销售</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">货品简称</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">颜色</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">吊牌价</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">近（7-14）天销售</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">近7天销售</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">上市日期</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">最近一次调入日期</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">累计销量</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">SKC畅滞销状态</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">累计日均售罄率</span></th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">近一周日均售罄率</span></th>
                                    <th colspan="26" rowspan="0">调入需求（系统）</th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">需求合计</span></th>
                                    <th colspan="26" rowspan="0">近一周销售明细</th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">销售合计</span></th>
                                    <th colspan="26" rowspan="0">库存明细(含运输在途和订单在途)</th>
                                    <th rowspan="2" class="diy-td-w72"><span style="width: 72px;">库存合计</span></th>
                                </tr>
                                <tr>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">S</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">M</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">L</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">XXL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">3XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">4XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">JM</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">27</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">28</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">29</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">30</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">31</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">32</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">33</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">34</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">36</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">37</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">38</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">39</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">40</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">41</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">42</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">43</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">44</span></th>
                                    <th class="diy-td-w30"><span class="sizeName" style="width: 30px;">45</span></th>

                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">S</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">M</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">L</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">XXL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">3XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">4XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">JM</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">27</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">28</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">29</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">30</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">31</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">32</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">33</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">34</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">36</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">37</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">38</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">39</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">40</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">41</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">42</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">43</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">44</span></th>
                                    <th class="diy-td-w30"><span class="sizeName1" style="width: 30px;">45</span></th>

                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">S</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">M</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">L</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">XXL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">3XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">4XL</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">JM</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">27</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">28</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">29</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">30</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">31</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">32</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">33</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">34</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">36</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">37</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">38</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">39</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">40</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">41</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">42</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">43</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">44</span></th>
                                    <th class="diy-td-w30"><span class="sizeName2" style="width: 30px;">45</span></th>
                                </tr>
                            </thead>
                        </table>
                    </div>
                </div>
                <div class="tb-body-container" id="tbc">
                    <div class="ibox-content">
                        <table class="loadTable">
                            <tbody class="loadList"></tbody>
                        </table>
                    </div>
                </div>
            </div>
            <div class="pageControl"></div>
        </div>
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="footer" runat="Server">
    <script src="../assets/js/plugins/webuploader/webuploader.min.js"></script>
    <script src="../assets/js/framework.js"></script>
    <script src="../assets/js/plugins/layer/laydate/laydate.js"></script>
    <script src="../assets/js/plugins/fancybox/jquery.fancybox.js"></script>
    <script src="../assets/js/page/pageControl.js"></script>
    <script src="../assets/js/page/tableControl.js"></script>
    <script>
        $(document).ready(function () {
            //自动收缩左边菜单栏
            commonUtil.autoLeftWidth();
            //模块ID
            var ModuleID = Y.getUrlParam("ModuleID");
            //获取按钮
            commonUtil.loadBtnList(ModuleID, function () { });
            //获取品类
            commonUtil.bindOdsErpSDMatModel2(['#serarch-category']);
            //获取类别
            commonUtil.bindOdsErpSdMatKind2(['#serarch-type']);
            //年份
            commonUtil.bindDwGlobalVariables({ dictValue: '年份' }, ['#serarch-year']);
            //季节
            commonUtil.bindDwGlobalVariables({ dictValue: '季节' }, ['#serarch-season']);
            //获取浏览器类型
            var sUserAgent = navigator.userAgent.toLowerCase();
            //初始化图片展示
            $(".fancybox").fancybox({
                openEffect: "none",
                closeEffect: "none"
            });
            //初始化日期控件
            var start = {
                elem: "#search-start",
                format: "YYYY-MM-DD",
                min: "2015-12-01",
                max: "2099-12-01",
                istime: false,
                istoday: true,
            };
            $('#search-start').val(laydate.now(-1, 'YYYY-MM-DD'));
            laydate(start);

            var provinceList = [];
            Y.API2('OdsErpBasArea', 'GetAllOdsErpBasAreaList', {}, function (data) {
                if (data.Success == false) {
                    swal(data.Message, '', 'error');
                } else {
                    data.map(function (item) {
                        provinceList.push(item);
                        $('#serarch-province').append('<option value="' + item[0].ParentID + '">' + item[0].ParentName + '</option>');
                    })
                }
            })

            //选择省份
            $('#serarch-province').change(function () {
                $('#serarch-city').empty();
                $('#serarch-city').append('<option value="">请选择</option>');
                var $this = $(this);
                provinceList.map(function (item) {
                    if (item[0].ParentID == $this.val()) {
                        item.map(function (city) {
                            $('#serarch-city').append('<option value="' + city.AreaID + '">' + city.AreaName + '</option>');
                        });
                        $('#serarch-city').val('');
                        return false;
                    }
                })
            });

            //计算容器大小
            var calcContainer = function () {
                //计算表格高度
                $('#tbc').height(
                    $('.right-side').height() - $('.condition').outerHeight() - $('.tb-head-container').outerHeight() -
                    (sUserAgent.indexOf('chrome') > -1 ? 109 : 118));
                //计算表格宽度
                $('#tbc').width($('#thc .loadTable').width());
            }

            $(window).resize(function () {
                //重新计算容器高度
                calcContainer();
            })

            //用于记录页数
            var page = 1;
            var loadList = function () {
                pageControl.init('DwAllocationRequire', 'GetDwAllocationRequire', {
                    LastMoveDate: $('#search-start').val(),
                    KindID: $('#serarch-type').val(),
                    ModelID: $('#serarch-category').val(),
                    YearNo: $('#serarch-year').val(),
                    SeasonName: $('#serarch-season').val(),
                    Keys: $('#search-keys').val().trim().replace(/'/g, ''),
                    ProID: $('#serarch-province').val(),
                    CityID: $('#serarch-city').val(),
                    Page: page,
                    Size: 500,
                    needLayer: true,
                    alwaysCallBack: function () {
                        $('#tbc .loadList').empty();
                    }
                }, function (result) {
                    page = result.page;
                    var tBody = [];
                    if (!Y.checkNull(result.data)) {
                        var rdi = result.data.Items;
                        if (rdi.length > 0) {
                            rdi.map(function (item, i) {
                                var tempChild = [];
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:250px;">' + (item[0].ShopName || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w250' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].ItemName || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;"><a class="fancybox" href="' + item[0].PicUrl + '" title="' + item[0].GoodsName + '"><img alt="image" class="pic" src="' + item[0].PicUrl + '" /></a></span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:100px;">' + (item[0].MaterialID || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w100' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].city_name || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].MonthSaleQty || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].GoodsName || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].Color || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].TagPrice ? parseFloat(item[0].TagPrice).toFixed(2) : ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].LastTwoWeekSaleQty || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].LastWeekSaleQty || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].SaleDate || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].LastMoveDate || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].TotalSaleQty || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].SKC_SluggishState || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].TotalDaySaleRate || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + (item[0].WeekDaySaleRate || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w72' });

                                var total = 0;
                                $('.sizeName').each(function () {
                                    var $this = $(this);
                                    var count = item.length;
                                    item.map(function (it, j) {
                                        if ($this.text() == it.SizeName) {
                                            total += (it.MoveRequireQty || 0);
                                            tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:30px;">' + (it.MoveRequireQty || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w30' });
                                            return false;
                                        }
                                        count--;
                                    });
                                    if (count == 0)
                                        tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:30px;">&nbsp;</span>', tdId: '', tdClass: 'diy-td-w30' });
                                });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + total + '</span>', tdId: '', tdClass: 'diy-td-w72' });

                                total = 0;
                                $('.sizeName1').each(function () {
                                    var $this = $(this);
                                    var count = item.length;
                                    item.map(function (it, j) {
                                        if ($this.text() == it.SizeName) {
                                            total += (it.WeekSaleDetail || 0);
                                            tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:30px;">' + (it.WeekSaleDetail || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w30' });
                                            return false;
                                        }
                                        count--;
                                    });
                                    if (count == 0)
                                        tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:30px;">&nbsp;</span>', tdId: '', tdClass: 'diy-td-w30' });
                                });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + total + '</span>', tdId: '', tdClass: 'diy-td-w72' });

                                total = 0;
                                $('.sizeName2').each(function () {
                                    var $this = $(this);
                                    var count = item.length;
                                    item.map(function (it, j) {
                                        if ($this.text() == it.SizeName) {
                                            total += (it.InventoryDetails || 0);
                                            tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:30px;">' + (it.InventoryDetails || ' ') + '</span>', tdId: '', tdClass: 'diy-td-w30' });
                                            return false;
                                        }
                                        count--;
                                    });
                                    if (count == 0)
                                        tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:30px;">&nbsp;</span>', tdId: '', tdClass: 'diy-td-w30' });
                                });
                                tempChild.push({ tdText: '', c: 0, r: 0, tdHtml: '<span style="width:72px;">' + total + '</span>', tdId: '', tdClass: 'diy-td-w72' });

                                var tempTr = {
                                    trClass: (i % 2 == 0 ? 'gradeX footable-even' : 'gradeX footable-odd'),
                                    children: tempChild
                                };
                                tBody.push(tempTr);
                            });
                            tableControl.initTbody('#tbc .loadTable', (tBody.length > 0 ? tBody : null), 0, null);
                            calcContainer();
                            return false;
                        }
                    }
                    calcContainer();
                    $('#tbc .loadList').append(
                        '<tr><td style="width:' + $('#thc th:first').width() + 'px;"><i class="fa fa-frown-o"></i></td>' +
                        '<td style="width:' + ($('#thc .loadTable').width() - $('#thc th:first').width()) + 'px;">无数据</td></tr>');
                });
            }
            loadList();
            calcContainer();

            //查询按钮
            $('.btns-container').on('click', '#btn-search', function () {
                loadList();
            })

            //下载按钮
            $(".btns-container").on("click", '#downloadBtn', function () {
                var conditionsArr = [];
                conditionsArr.push({ column: "req.Allocation_Date", value: $('#search-start').val(), operator: "=", connector: "and" });
                conditionsArr.push({ column: "area.ParentId", value: $('#serarch-province').val(), operator: "=", connector: "and" });
                conditionsArr.push({ column: "area.AreaID", value: $('#serarch-city').val(), operator: "=", connector: "and" });
                conditionsArr.push({ column: "item.ModelID", value: $('#serarch-category').val(), operator: "=", connector: "and" });
                conditionsArr.push({ column: "mat.KindID", value: $('#serarch-type').val(), operator: "=", connector: "and" });
                conditionsArr.push({ column: "mat.YearNo", value: $('#serarch-year').val(), operator: "=", connector: "and" });
                conditionsArr.push({ column: "mat.SeasonID", value: $('#serarch-season').val(), operator: "=", connector: "and" });
                conditionsArr.push({ column: "shop.ShopName", value: $('#search-keys').val().trim().replace(/'/g, ''), operator: "like", connector: "and" });
                conditionsArr = JSON.stringify(conditionsArr);
                $.Export({
                    filetype: 'DWALLOCATIONREQUIRE',
                    filename: '店间调拨需求表',
                    conditions: encodeURIComponent(conditionsArr),
                    after: function () {
                        //回调方法
                        //loadList(1);
                        swal("导出成功!");
                    }
                });
            });
        })
    </script>
</asp:Content>

